Optimal. Leaf size=207 \[ -\frac {\left (12 a^2-18 a b+5 b^2\right ) \tanh ^{-1}\left (\frac {\sqrt {a+b \sin (c+d x)}}{\sqrt {a-b}}\right )}{32 (a-b)^{3/2} d}+\frac {\left (12 a^2+18 a b+5 b^2\right ) \tanh ^{-1}\left (\frac {\sqrt {a+b \sin (c+d x)}}{\sqrt {a+b}}\right )}{32 (a+b)^{3/2} d}-\frac {\sec ^2(c+d x) \sqrt {a+b \sin (c+d x)} \left (a b-\left (6 a^2-5 b^2\right ) \sin (c+d x)\right )}{16 \left (a^2-b^2\right ) d}+\frac {\sec ^3(c+d x) \sqrt {a+b \sin (c+d x)} \tan (c+d x)}{4 d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.21, antiderivative size = 207, normalized size of antiderivative = 1.00, number of steps
used = 7, number of rules used = 6, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.261, Rules used = {2747, 751, 837,
841, 1180, 212} \begin {gather*} -\frac {\left (12 a^2-18 a b+5 b^2\right ) \tanh ^{-1}\left (\frac {\sqrt {a+b \sin (c+d x)}}{\sqrt {a-b}}\right )}{32 d (a-b)^{3/2}}+\frac {\left (12 a^2+18 a b+5 b^2\right ) \tanh ^{-1}\left (\frac {\sqrt {a+b \sin (c+d x)}}{\sqrt {a+b}}\right )}{32 d (a+b)^{3/2}}-\frac {\sec ^2(c+d x) \sqrt {a+b \sin (c+d x)} \left (a b-\left (6 a^2-5 b^2\right ) \sin (c+d x)\right )}{16 d \left (a^2-b^2\right )}+\frac {\tan (c+d x) \sec ^3(c+d x) \sqrt {a+b \sin (c+d x)}}{4 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 751
Rule 837
Rule 841
Rule 1180
Rule 2747
Rubi steps
\begin {align*} \int \sec ^5(c+d x) \sqrt {a+b \sin (c+d x)} \, dx &=\frac {b^5 \text {Subst}\left (\int \frac {\sqrt {a+x}}{\left (b^2-x^2\right )^3} \, dx,x,b \sin (c+d x)\right )}{d}\\ &=\frac {\sec ^3(c+d x) \sqrt {a+b \sin (c+d x)} \tan (c+d x)}{4 d}-\frac {b^3 \text {Subst}\left (\int \frac {-3 a-\frac {5 x}{2}}{\sqrt {a+x} \left (b^2-x^2\right )^2} \, dx,x,b \sin (c+d x)\right )}{4 d}\\ &=-\frac {\sec ^2(c+d x) \sqrt {a+b \sin (c+d x)} \left (a b-\left (6 a^2-5 b^2\right ) \sin (c+d x)\right )}{16 \left (a^2-b^2\right ) d}+\frac {\sec ^3(c+d x) \sqrt {a+b \sin (c+d x)} \tan (c+d x)}{4 d}+\frac {b \text {Subst}\left (\int \frac {\frac {1}{4} a \left (12 a^2-13 b^2\right )+\frac {1}{4} \left (6 a^2-5 b^2\right ) x}{\sqrt {a+x} \left (b^2-x^2\right )} \, dx,x,b \sin (c+d x)\right )}{8 \left (a^2-b^2\right ) d}\\ &=-\frac {\sec ^2(c+d x) \sqrt {a+b \sin (c+d x)} \left (a b-\left (6 a^2-5 b^2\right ) \sin (c+d x)\right )}{16 \left (a^2-b^2\right ) d}+\frac {\sec ^3(c+d x) \sqrt {a+b \sin (c+d x)} \tan (c+d x)}{4 d}+\frac {b \text {Subst}\left (\int \frac {\frac {1}{4} a \left (12 a^2-13 b^2\right )-\frac {1}{4} a \left (6 a^2-5 b^2\right )+\frac {1}{4} \left (6 a^2-5 b^2\right ) x^2}{-a^2+b^2+2 a x^2-x^4} \, dx,x,\sqrt {a+b \sin (c+d x)}\right )}{4 \left (a^2-b^2\right ) d}\\ &=-\frac {\sec ^2(c+d x) \sqrt {a+b \sin (c+d x)} \left (a b-\left (6 a^2-5 b^2\right ) \sin (c+d x)\right )}{16 \left (a^2-b^2\right ) d}+\frac {\sec ^3(c+d x) \sqrt {a+b \sin (c+d x)} \tan (c+d x)}{4 d}-\frac {\left (12 a^2-18 a b+5 b^2\right ) \text {Subst}\left (\int \frac {1}{a-b-x^2} \, dx,x,\sqrt {a+b \sin (c+d x)}\right )}{32 (a-b) d}+\frac {\left (12 a^2+18 a b+5 b^2\right ) \text {Subst}\left (\int \frac {1}{a+b-x^2} \, dx,x,\sqrt {a+b \sin (c+d x)}\right )}{32 (a+b) d}\\ &=-\frac {\left (12 a^2-18 a b+5 b^2\right ) \tanh ^{-1}\left (\frac {\sqrt {a+b \sin (c+d x)}}{\sqrt {a-b}}\right )}{32 (a-b)^{3/2} d}+\frac {\left (12 a^2+18 a b+5 b^2\right ) \tanh ^{-1}\left (\frac {\sqrt {a+b \sin (c+d x)}}{\sqrt {a+b}}\right )}{32 (a+b)^{3/2} d}-\frac {\sec ^2(c+d x) \sqrt {a+b \sin (c+d x)} \left (a b-\left (6 a^2-5 b^2\right ) \sin (c+d x)\right )}{16 \left (a^2-b^2\right ) d}+\frac {\sec ^3(c+d x) \sqrt {a+b \sin (c+d x)} \tan (c+d x)}{4 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 1.52, size = 224, normalized size = 1.08 \begin {gather*} \frac {-\sqrt {a-b} (a+b)^2 \left (12 a^2-18 a b+5 b^2\right ) \tanh ^{-1}\left (\frac {\sqrt {a+b \sin (c+d x)}}{\sqrt {a-b}}\right )+(a-b)^2 \sqrt {a+b} \left (12 a^2+18 a b+5 b^2\right ) \tanh ^{-1}\left (\frac {\sqrt {a+b \sin (c+d x)}}{\sqrt {a+b}}\right )+\frac {1}{2} \left (a^2-b^2\right ) \sec ^4(c+d x) \sqrt {a+b \sin (c+d x)} \left (-2 a b-2 a b \cos (2 (c+d x))+\left (22 a^2-21 b^2\right ) \sin (c+d x)+6 a^2 \sin (3 (c+d x))-5 b^2 \sin (3 (c+d x))\right )}{32 \left (a^2-b^2\right )^2 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(470\) vs.
\(2(183)=366\).
time = 2.44, size = 471, normalized size = 2.28
method | result | size |
default | \(\frac {-\frac {3 b \left (a +b \sin \left (d x +c \right )\right )^{\frac {3}{2}} a}{16 \left (b \sin \left (d x +c \right )-b \right )^{2} \left (a +b \right )}-\frac {5 b^{2} \left (a +b \sin \left (d x +c \right )\right )^{\frac {3}{2}}}{32 \left (b \sin \left (d x +c \right )-b \right )^{2} \left (a +b \right )}+\frac {3 \sqrt {a +b \sin \left (d x +c \right )}\, a b}{16 \left (b \sin \left (d x +c \right )-b \right )^{2}}+\frac {7 \sqrt {a +b \sin \left (d x +c \right )}\, b^{2}}{32 \left (b \sin \left (d x +c \right )-b \right )^{2}}+\frac {3 \arctanh \left (\frac {\sqrt {a +b \sin \left (d x +c \right )}}{\sqrt {a +b}}\right ) a^{2}}{8 \left (a +b \right )^{\frac {3}{2}}}+\frac {9 \arctanh \left (\frac {\sqrt {a +b \sin \left (d x +c \right )}}{\sqrt {a +b}}\right ) a b}{16 \left (a +b \right )^{\frac {3}{2}}}+\frac {5 \arctanh \left (\frac {\sqrt {a +b \sin \left (d x +c \right )}}{\sqrt {a +b}}\right ) b^{2}}{32 \left (a +b \right )^{\frac {3}{2}}}-\frac {3 b \left (a +b \sin \left (d x +c \right )\right )^{\frac {3}{2}} a}{16 \left (b \sin \left (d x +c \right )+b \right )^{2} \left (a -b \right )}+\frac {5 b^{2} \left (a +b \sin \left (d x +c \right )\right )^{\frac {3}{2}}}{32 \left (b \sin \left (d x +c \right )+b \right )^{2} \left (a -b \right )}+\frac {3 \sqrt {a +b \sin \left (d x +c \right )}\, a b}{16 \left (b \sin \left (d x +c \right )+b \right )^{2}}-\frac {7 \sqrt {a +b \sin \left (d x +c \right )}\, b^{2}}{32 \left (b \sin \left (d x +c \right )+b \right )^{2}}+\frac {3 \arctan \left (\frac {\sqrt {a +b \sin \left (d x +c \right )}}{\sqrt {-a +b}}\right ) a^{2}}{8 \left (a -b \right ) \sqrt {-a +b}}-\frac {9 \arctan \left (\frac {\sqrt {a +b \sin \left (d x +c \right )}}{\sqrt {-a +b}}\right ) a b}{16 \left (a -b \right ) \sqrt {-a +b}}+\frac {5 \arctan \left (\frac {\sqrt {a +b \sin \left (d x +c \right )}}{\sqrt {-a +b}}\right ) b^{2}}{32 \left (a -b \right ) \sqrt {-a +b}}}{d}\) | \(471\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: ValueError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \sqrt {a + b \sin {\left (c + d x \right )}} \sec ^{5}{\left (c + d x \right )}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 5.93, size = 358, normalized size = 1.73 \begin {gather*} \frac {b^{5} {\left (\frac {{\left (12 \, a^{2} - 18 \, a b + 5 \, b^{2}\right )} \arctan \left (\frac {\sqrt {b \sin \left (d x + c\right ) + a}}{\sqrt {-a + b}}\right )}{{\left (a b^{5} - b^{6}\right )} \sqrt {-a + b}} - \frac {{\left (12 \, a^{2} + 18 \, a b + 5 \, b^{2}\right )} \arctan \left (\frac {\sqrt {b \sin \left (d x + c\right ) + a}}{\sqrt {-a - b}}\right )}{{\left (a b^{5} + b^{6}\right )} \sqrt {-a - b}} - \frac {2 \, {\left (6 \, {\left (b \sin \left (d x + c\right ) + a\right )}^{\frac {7}{2}} a^{2} - 18 \, {\left (b \sin \left (d x + c\right ) + a\right )}^{\frac {5}{2}} a^{3} + 18 \, {\left (b \sin \left (d x + c\right ) + a\right )}^{\frac {3}{2}} a^{4} - 6 \, \sqrt {b \sin \left (d x + c\right ) + a} a^{5} - 5 \, {\left (b \sin \left (d x + c\right ) + a\right )}^{\frac {7}{2}} b^{2} + 14 \, {\left (b \sin \left (d x + c\right ) + a\right )}^{\frac {5}{2}} a b^{2} - 23 \, {\left (b \sin \left (d x + c\right ) + a\right )}^{\frac {3}{2}} a^{2} b^{2} + 14 \, \sqrt {b \sin \left (d x + c\right ) + a} a^{3} b^{2} + 9 \, {\left (b \sin \left (d x + c\right ) + a\right )}^{\frac {3}{2}} b^{4} - 8 \, \sqrt {b \sin \left (d x + c\right ) + a} a b^{4}\right )}}{{\left (a^{2} b^{4} - b^{6}\right )} {\left ({\left (b \sin \left (d x + c\right ) + a\right )}^{2} - 2 \, {\left (b \sin \left (d x + c\right ) + a\right )} a + a^{2} - b^{2}\right )}^{2}}\right )}}{32 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {\sqrt {a+b\,\sin \left (c+d\,x\right )}}{{\cos \left (c+d\,x\right )}^5} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________